﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Serialization;

namespace Mirror.Models
{
    public class Provider
    {
        [XmlAttribute("Name")]
        public String Name;
        public List<Symbol> Symbols;

        public Provider()
            : this("")
        {

        }

        public Provider(String Name)
        {
            this.Name = Name;
            this.Symbols = new List<Symbol>();
        }

        public void Add(Symbol Symbol)
        {
            Symbols.Add(Symbol);
        }

        public Symbol GetSymbol(String Name)
        {
            foreach (Symbol s in Symbols)
            {
                if (s.Name == Name)
                {
                    return s;
                }
            }
            return null;
        }
    }
}
